import Vue from "vue";
import VueRouter from "vue-router";
import Home from "../views/index/Home.vue";

Vue.use(VueRouter);

const routes = [
  {
    path: "/Home",
    name: "Home",
    component: Home,
  },
  {
    path: "/allmonth",
    name: "allmonth",
    component: () => import("@/views/index/allmonth.vue"),
  },
  {
    path: "/Find",
    name: "Find",
    component: () => import("@/views/Find/Find.vue"),
  },
  {
    path: "/Mine",
    name: "Mine",
    component: () => import("@/views/Mine/Mine.vue"),
  },
  {
    path: "/login",
    name: "login",
    component: () => import("@/views/Mine/login.vue"),
  },
  {
    path: "/register",
    name: "register",
    component: () => import("@/views/Mine/register.vue"),
  },
  {
    path: "/detail",
    name: "detail",
    component: () => import("@/views/detail/detail.vue"),
  },
  {
    path: "/zhiwu",
    name: "zhiwu",
    component: () => import("@/views/zhiwu/zhiwu.vue"),
  },
  {
    path: "/mark",
    name: "mark",
    component: () => import("@/views/mark/mark.vue"),
  },
  {
    path: "/address",
    name: "address",
    component: () => import("@/views/shopping/address.vue"),
  },
  {
    path: "/person",
    name: "person",
    component: () => import("@/views/shopping/person.vue"),
  },
  {
    path: "/shoping",
    name: "shopping",
    component: () => import("@/views/shopping/shopping.vue"),
  },  

  //banner
  {
    path: "/banner",
    name: "banner",
    component: () => import("@/views/index/banner.vue"),
  },

  { path: "*", name: "404", redirect: "/Home" },
];

const router = new VueRouter({
  linkActiveClass: "routerActive",
  mode: "hash",
  base: process.env.BASE_URL,
  routes,
});

export default router;
